package com.gitee.shoes.service.impl;

import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.gitee.shoes.dao.ProductImageMapper;
import com.gitee.shoes.entity.ProductImage;
import com.gitee.shoes.service.IProductImageService;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author LYH
 * @since 2020-12-09
 */
@Service
public class ProductImageServiceImpl extends ServiceImpl<ProductImageMapper, ProductImage> implements IProductImageService {

    @Override
    public List<ProductImage> findAllByProductId(Long productId) {
        return list(Wrappers.<ProductImage>lambdaQuery().eq(ProductImage::getProductId, productId));
    }
}
